
package StackAlgorithm;

/**
 *
 * @author hazem
 */
public class Tile
{
	public  int level;
	public int row;
	public int column;

	public Tile(int l, int r, int c)
	{
		level = l;
		row = r;
		column = c;
	}
	public Tile ()
	{
		this(0,0,0);
	}
	public boolean compareTiles(Tile currentTile)
	{
		if (level==currentTile.level&&row==currentTile.row&&column==currentTile.column)
			return true;
		else return false;
	}
	public void setTile(int newLevel,int newRow,int newColumn)
	{
		level=newLevel;
		row=newRow;
		column = newColumn;
	}
	public void setLevel(int newLevel)
	{
		level=newLevel;
	}
	public void setColumn(int newColumn)
	{
		column = newColumn;
	}
	public void setRow( int newRow)
	{
		row=newRow;
	}
	public static void main (String [] args)
	{
		Tile a = new Tile(2,3,1);
		Tile b = new Tile (2,3,1);
		Tile c = new Tile (2,3,3);
		System.out.println(a.compareTiles(b));
		System.out.println(a.compareTiles(c));
		}

}
